using System;
using System.Collections.Generic;
using System.Data.Linq.Mapping;
using InfoTech.Core.Data.Attributes;
using InfoTech.Core.Data.Dataable;
using InfoTech.Core.Data.Persistence;
using InfoTech.Utilities.Generic;

namespace InfoTech.LanTranh.MucVu.Bussiness
{
	[Serializable]
	[ExtraTable(Name = "GHICHU", Schema="dbo")]
	[Table(Name = "[dbo].[GHICHU]")]
	public partial class GHICHU : ObjPersistence, IDeleteable, IUpdateable, IInsertable, ISelectable, IDeleteablebyId, IUpdateablebyId, ISelectablebyId
	{

		#region Fields

		private System.Guid _maghichu;

		private System.String _manguon;

		private System.String _tenghichu;

		private System.String _noidung;

		private System.DateTime? _ngaytao;

		private System.DateTime? _ngaychinhsua;

		#endregion

		#region Properties

		[ExtraColumn(DbType = "uniqueidentifier", Length = 0, TypeName = "System.Guid", Type = typeof(System.Guid), CanBeNull = false)]
		[Column(Name = "MAGHICHU", DbType = "uniqueidentifier", IsPrimaryKey = true, CanBeNull = false)]
		public System.Guid MAGHICHU
		{
			get
			{
				return _maghichu;
			}
			set
			{
				OnChanged(this, "MAGHICHU");
				_maghichu = value;
			}
		}

		[ExtraColumn(DbType = "nvarchar", Length = 100, TypeName = "System.String", Type = typeof(System.String), CanBeNull = true)]
		[Column(Name = "MANGUON", DbType = "nvarchar(100)", IsPrimaryKey = false, CanBeNull = true)]
		public System.String MANGUON
		{
			get
			{
				return _manguon;
			}
			set
			{
				OnChanged(this, "MANGUON");
				_manguon = value;
			}
		}

		[ExtraColumn(DbType = "nvarchar", Length = 100, TypeName = "System.String", Type = typeof(System.String), CanBeNull = true)]
		[Column(Name = "TENGHICHU", DbType = "nvarchar(100)", IsPrimaryKey = false, CanBeNull = true)]
		public System.String TENGHICHU
		{
			get
			{
				return _tenghichu;
			}
			set
			{
				OnChanged(this, "TENGHICHU");
				_tenghichu = value;
			}
		}

		[ExtraColumn(DbType = "nvarchar", Length = 2000, TypeName = "System.String", Type = typeof(System.String), CanBeNull = true)]
		[Column(Name = "NOIDUNG", DbType = "nvarchar(2000)", IsPrimaryKey = false, CanBeNull = true)]
		public System.String NOIDUNG
		{
			get
			{
				return _noidung;
			}
			set
			{
				OnChanged(this, "NOIDUNG");
				_noidung = value;
			}
		}

		[ExtraColumn(DbType = "datetime", Length = 0, TypeName = "System.DateTime", Type = typeof(System.DateTime), CanBeNull = true)]
		[Column(Name = "NGAYTAO", DbType = "datetime", IsPrimaryKey = false, CanBeNull = true)]
		public System.DateTime? NGAYTAO
		{
			get
			{
				return _ngaytao;
			}
			set
			{
				OnChanged(this, "NGAYTAO");
				_ngaytao = value;
			}
		}

		[ExtraColumn(DbType = "datetime", Length = 0, TypeName = "System.DateTime", Type = typeof(System.DateTime), CanBeNull = true)]
		[Column(Name = "NGAYCHINHSUA", DbType = "datetime", IsPrimaryKey = false, CanBeNull = true)]
		public System.DateTime? NGAYCHINHSUA
		{
			get
			{
				return _ngaychinhsua;
			}
			set
			{
				OnChanged(this, "NGAYCHINHSUA");
				_ngaychinhsua = value;
			}
		}

		#endregion

		#region Reflector

		public System.Type Reflector()
		{
			return typeof(GHICHU);
		}
		public object Current
		{
			get { return this; }
		}

		#endregion

	}
}
